import request from '@/utils/request'
export default {

  getList(currentPage,pageSize,sort) {
    return request({
      url: `/sort/search/${currentPage}/${pageSize}`,
      method: 'post',
      data:sort
    })
  },
  getSortAll(){
    return request({
        url: `/sort`,
        method: 'get',
    })
  },
  add(sortAdd) {
    return request({
      url: `/sort/add`,
      method: 'post',
      data:sortAdd
    })
  },
  update(sort) {
    return request({
      url: `/sort/edit`,
      method: 'put',
      data:sort
    })
  },
  getById(id) {
    return request({
      url: `/sort/get/${id}`,
      method: 'get'
    })
  },
  delete(id) {
    return request({
      url: `/sort/${id}`,
      method: 'delete'
    })
  },
}
